/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.source.entity.subtitle;

import com.google.common.collect.Lists;
import com.thinkgem.jeesite.common.persistence.DataEntity;
import com.thinkgem.jeesite.modules.source.entity.EleSourceGroup;
import com.thinkgem.jeesite.modules.sys.entity.User;

import org.hibernate.validator.constraints.Length;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlTransient;
import java.util.List;

/**
 * 字幕资源管理Entity
 * @author ZC
 * @version 2017-04-22
 */
@XmlRootElement(name="subcfg")
public class EleSourceSubtitleGroup extends DataEntity<EleSourceSubtitleGroup> {
	
	private static final long serialVersionUID = 1L;
	private String name;		// 名称
	private String fontsize;		// 字体大小
	private String fgcolor;		// 文字颜色
	private String bgcolor;		// 背景颜色
	private String align;		// align
	private Integer alpha;

	private String bgimage;		// 背景图片
	private String speed;		// 滚动速度
	private String orientation;		// 文字滚动方向
	private String toFloor;		// 对应楼层
	private String area;
	private List<EleSourceSubtitle> eleSourceSubtitleList = Lists.newArrayList();		// 子表列表
	private String groupId;
	private EleSourceGroup group;
	public List<User> users = null;

	@XmlTransient
	public List<User> getUsers() {
		return users;
	}

	public void setUsers(List<User> users) {
		this.users = users;
	}
	@XmlTransient
	public EleSourceGroup getGroup() {
		return group;
	}

	public void setGroup(EleSourceGroup group) {
		this.group = group;
	}
	@XmlTransient
	public String getGroupId() {
		return groupId;
	}

	public void setGroupId(String groupId) {
		this.groupId = groupId;
	}
	public EleSourceSubtitleGroup() {
		super();
	}

	public EleSourceSubtitleGroup(String id){
		super(id);
	}
	@XmlTransient
	@Length(min=0, max=50, message="视频名称长度必须介于 0 和 50 之间")
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@XmlElement(name = "fontsize")
	public String getFontsize() {
		return fontsize;
	}

	public void setFontsize(String fontsize) {
		this.fontsize = fontsize;
	}
	
	@XmlElement(name = "fgcolor")
	@Length(min=0, max=255, message="文字颜色长度必须介于 0 和 255 之间")
	public String getFgcolor() {
		return fgcolor;
	}

	public void setFgcolor(String fgcolor) {
		this.fgcolor = fgcolor;
	}
	
	@XmlElement(name = "bgcolor")
	@Length(min=0, max=255, message="背景颜色长度必须介于 0 和 255 之间")
	public String getBgcolor() {
		return bgcolor;
	}

	public void setBgcolor(String bgcolor) {
		this.bgcolor = bgcolor;
	}

	@XmlTransient
	@Length(min=0, max=100, message="字体颜色长度必须介于 0 和 100 之间")
	public String getAlign() {
		return align;
	}
	public void setAlign(String align) {
		this.align = align;
	}

	@XmlElement(name = "bgimage")
	@Length(min=0, max=255, message="背景图片长度必须介于 0 和 255 之间")
	public String getBgimage() {
		return bgimage;
	}

	public void setBgimage(String bgimage) {
		this.bgimage = bgimage;
	}
	
	@XmlElement(name = "speed")
	public String getSpeed() {
		return speed;
	}

	public void setSpeed(String speed) {
		this.speed = speed;
	}
	
	@XmlElement(name = "orientation")
	@Length(min=0, max=255, message="文字滚动方向长度必须介于 0 和 255 之间")
	public String getOrientation() {
		return orientation;
	}

	public void setOrientation(String orientation) {
		this.orientation = orientation;
	}
	
	@XmlElement(name = "to_floor")
	@Length(min=0, max=10, message="对应楼层长度必须介于 0 和 10 之间")
	public String getToFloor() {
		return toFloor;
	}

	public void setToFloor(String toFloor) {
		this.toFloor = toFloor;
	}
	@XmlTransient
	public String getArea() {
		return area;
	}

	public void setArea(String area) {
		this.area = area;
	}
	@XmlElement(name = "sub")
	public List<EleSourceSubtitle> getEleSourceSubtitleList() {
		return eleSourceSubtitleList;
	}

	public void setEleSourceSubtitleList(List<EleSourceSubtitle> eleSourceSubtitleList) {
		this.eleSourceSubtitleList = eleSourceSubtitleList;
	}

	public Integer getAlpha(){
		return alpha;
	}

	public void setAlpha(Integer alpha){
		this.alpha = alpha;
	}
}